﻿using System;
using System.Collections.Generic;

namespace MVCMS.Core.Model
{
   ///<summary>Default page class for MVCMS</summary>
   public class CmsPage
    {
       ///<summary>Id of the page</summary>
       public Guid ID { get; set; }
       
       ///<summary>Name of the page</summary>
       public string Name { get; set; }

       ///<summary>MetaData for the page</summary>
       public CmsMetaData MetaData { get; set; }

       public string Controller { get; set; }

       public string Action { get; set; }

       public string View { get; set; }

       public Dictionary<string, CmsSection> Sections { get; private set; }

       public CmsFolder Parent {
           get { return Parent; }
           set
           {

               Parent.Remove(this);
               Parent = value;
           } 
       }

   
   }

}
